Skip to content

Address hardcoded 2018 MECS in GHG methods - #688

Open
catherinebirney wants to merge 16 commits into
mainfrom
cb_mecs
Open

Address hardcoded 2018 MECS in GHG methods#688
catherinebirney wants to merge 16 commits into
mainfrom
cb_mecs

Conversation

@catherinebirney

@catherinebirney catherinebirney commented Aug 21, 2026

Copy link
Copy Markdown
Member

cc:
Closes: #488

What changed? Why?

  • Address the hard coded use of 2018 MECS data when we want the flexibility of using 2018 or 2022 in the GHG FBS methods
  • The hardcoded methods relied on EPA_GHGI attribution tables, which needed to be replaced with UMD_GHGIA data
  • Modified our approach by moving away from the EIA_MECS_Energy_CEDA_allocaition.yaml FBA - which called on CEDA functions and instead created FBS methods with use the flowsa logic/approach. This does modify how the EIA MECS data is used for attribution. The FBA calculated kg CO₂e weights, which were then used to allocate the GHG data. The FBS does not convert the MECS data to kg co2e, keeping data in original units - still used to proportionally attribute GHG.
  • Moving to FBS also allows us to use the Cornerstone_2025 industry spec and makes it clear/easy to follow what data sources are being used for attribution, rather than the buried, hard coded sources.
  • We estimate suppressed data and map the MECS sectors to target Cornerstone industry spec. We fully rely on the built in mapping logic that exists in flowsa to align data sets. Previously, CEDA had a specific list of relevant sectors.

Intentionally changed approach from CEDA:

  • NEU petroleum product split (HGL / asphalt / remainder): CEDA merged all three into one FBA row (Petroleum, non energy) and nested a single combined EPA bucket. Now we keeps separate activity sets with product-specific MECS to BEA weight pairing.
  • F01000 transport lubricants in NEU: We routes a PCE/price-scaled share of petroleum NEU to households (F01000) via neu_transport. CEDA approach was 0 on F01000 in T_3_14. Now +7.3 Mt (2018) and +3.5 Mt (2024) on F01000. CEDA did not assess households - our approach does.
  • FBS mapping: Built in flowsa approach of estimating suppressed data and merging datasets on sectors is different than the lists of relevant industry codes identified in CEDA approach - results in some shifts of results between sectors.
  • Using UMD_GHGIA data over EPA_GHGI data
  • Using 2022 MECS within timeseries GHG methods.

Testing

Total FBS values for 2018 and 2024 are the same as we see on Main. There is a shift in results for T-3-11 and T-3-14.

Compared the results for the 2018 and 2024 GHG Cornerstone FBS

2018 national by NAICS-2 (nonzero diff)

Sector Main Mt cb_mecs Mt Diff Mt Pct diff
HH / F01000 1408.892 1416.226 +7.334 +0.52
Mfg 32 302.978 298.001 -4.977 -1.64
Transp 48 467.723 463.501 -4.222 -0.90
Construction 180.325 183.035 +2.710 +1.50
Gov GSLG* 405.439 403.655 -1.784 -0.44
Ag 1027.129 1028.149 +1.020 +0.10
Special S00 43.991 43.032 -0.959 -2.18
Mfg 33 74.966 75.810 +0.844 +1.13
Mining 530.969 531.774 +0.805 +0.15
Mfg 31 5.880 5.478 -0.402 -6.84
Transp 49 39.348 38.979 -0.369 -0.94

2018 T_3_11 by NAICS-2 (nonzero diff)

Sector Main Mt cb_mecs Mt Diff Mt Pct diff
Mfg 32 89.642 86.887 -2.755 -3.07
Construction 165.795 168.505 +2.710 +1.63
Mfg 33 10.123 8.934 -1.188 -11.74
Ag 383.136 384.155 +1.020 +0.27
Mining 188.819 189.624 +0.805 +0.43
Mfg 31 3.789 3.197 -0.592 -15.61
Utilities 0.296 0.296 +0.000 +0.08

2018 T_3_14 by NAICS-2 (nonzero diff)

Sector Main Mt cb_mecs Mt Diff Mt Pct diff
HH / F01000 0.000 7.334 +7.334 n/a
Transp 48 6.839 2.617 -4.222 -61.73
Mfg 32 68.481 66.259 -2.223 -3.25
Mfg 33 0.432 2.465 +2.033 +470.76
Gov GSLG* 3.312 1.528 -1.784 -53.86
Special S00 1.781 0.822 -0.959 -53.86
Transp 49 0.684 0.316 -0.369 -53.86
Mfg 31 0.000 0.190 +0.190 n/a

2024 national by NAICS-2 (nonzero diff)

Sector Main Mt cb_mecs Mt Diff Mt Pct diff
Mfg 33 75.240 94.546 +19.306 +25.66
Construction 164.357 153.067 -11.290 -6.87
Ag 992.957 988.709 -4.248 -0.43
HH / F01000 1304.340 1307.816 +3.476 +0.27
Mining 432.673 429.336 -3.337 -0.77
Transp 48 520.127 518.136 -1.990 -0.38
Gov GSLG* 414.719 413.877 -0.842 -0.20
Special S00 43.465 43.012 -0.453 -1.04
Mfg 31 5.422 5.088 -0.335 -6.18
Transp 49 39.217 39.043 -0.174 -0.44
Mfg 32 286.152 286.048 -0.104 -0.04
Utilities 1516.089 1516.082 -0.008 -0.00

2024 T_3_11 by NAICS-2 (nonzero diff)

Sector Main Mt cb_mecs Mt Diff Mt Pct diff
Mfg 32 71.416 91.606 +20.190 +28.27
Construction 147.087 135.797 -11.290 -7.68
Ag 389.614 385.366 -4.248 -1.09
Mining 171.291 167.939 -3.352 -1.96
Mfg 33 8.065 7.172 -0.893 -11.07
Mfg 31 3.019 2.619 -0.399 -13.23
Utilities 0.309 0.301 -0.008 -2.52

2024 T_3_14 by NAICS-2 (nonzero diff)

Sector Main Mt cb_mecs Mt Diff Mt Pct diff
Mfg 32 84.352 64.058 -20.294 -24.06
Mfg 33 0.523 20.721 +20.198 +3865.17
HH / F01000 0.000 3.476 +3.476 n/a
Transp 48 3.210 1.220 -1.990 -62.00
Gov GSLG* 1.554 0.712 -0.842 -54.19
Special S00 0.836 0.383 -0.453 -54.19
Transp 49 0.321 0.147 -0.174 -54.19
Mfg 31 0.000 0.064 +0.064 n/a
Mining 5.204 5.218 +0.015 +0.28

@catherinebirney catherinebirney self-assigned this Aug 21, 2026
Comment thread bedrock/utils/config/source_catalog.yaml Outdated
@catherinebirney
catherinebirney marked this pull request as ready for review September 1, 2026 16:12
@bl-young

bl-young commented Sep 2, 2026

Copy link
Copy Markdown
Member

Energy FBS national totals (2022 MECS) — follow-up fix incoming

While building the NEU activity-set pivot for this review, I found a pipeline bug that inflates 2022 MECS energy weights (e.g. Table 2.1 HGL national FBS ≈ 2,176 mmbbl vs MECS 31-33 control ≈ 870 mmbbl, ~2.5×).

Root cause: EIA_MECS_Energy is assigned NAICS_2022_Code for the 2022 survey (source_catalog.yaml). Energy methods target Cornerstone (target_naics_year: 2017), so map_to_sectors calls convert_naics_year (2022 → 2017). That path is correct for NAICS vintage conversion, but the final aggregation step reassigns group_id = df.index on every fan-out row after the Cornerstone crosswalk maps one MECS activity to multiple target sectors. Proportional BEA attribution then treats each fan-out row as an independent full group instead of splitting one group_total.

2018 MECS does not hit this path (source and target are both NAICS 2017, so convert_naics_year is skipped and group_id survives fan-out). National HGL stays ≈ 888 mmbbl.

Separate note: Change in disclosure for some sectors causes significant jumps between MECS years.

There are just a few cases, but data suppression, especially D (which is to avoid revealing confidential information) is different between 2018 and 2022. For example, **32531 has a +10.7 Mt jump in which aligns with 2022 MECS disclosing Table 2.1 NG feedstock for 325311 that 2018 suppresses (D → 0). We may want to consider alternate approaches to handle these cases (which are different than the * which reflect small amounts).

@bl-young

bl-young commented Sep 2, 2026

Copy link
Copy Markdown
Member

Also turns out there are some extra blank columns in the 2022 Non-energy tables so the fuels were mis aligned

---------

Co-authored-by: Ben Young <ben.young@erg.com>
@bl-young

bl-young commented Sep 4, 2026

Copy link
Copy Markdown
Member

Ok after we pulled in those additional fixes, I am reviewing this with a few frames in mind:

  1. When we use this new approach, but fix it to 2018 MECS, how different is it from our current pinned v0.3 GHG FBS? This should help tease out differences that result from the methodology of this revision, separate from the vintage update. (I've created a separate FBS method that does this).
  2. I'm looking to confirm that there are no non-MECS related changes in the results (note this also includes understanding how the manufacturing and non-manufacturing shares may have changed).
  3. I'm trying to tease out what, if any, mapping differences that are rolled in to this change might impact.
  4. And finally, the update to use 2022 MECS data will likely significantly impact some of the splits of emissions - this is expected - we just need to understand how and why.

I'm referring to these methods as:
A - our pinned v0.3 GHG FBS
B - 2024 GHG FBS with the new approach, but forcing it to use 2018 MECS (to tease out methodology changes only)
C - the new designed 2024 GHG FBS, using 2022 MECS.

@bl-young

bl-young commented Sep 4, 2026

Copy link
Copy Markdown
Member

Verdict so far: Isolation is working as designed. National totals match (4,924.087 Mt). Only T_3_11 and T_3_14 move. Everything else is an explicit no-change. A→C decomposes cleanly into A→B + B→C (zero residual).

What the three arms are saying

Contrast Abs sector churn Story
A→B (method) T_3_14 ~41 Mt, T_3_11 ~33 Mt Smaller; chem + HH lubricants dominate
B→C (vintage) T_3_11 ~90 Mt, T_3_14 ~48 Mt Larger; survey/disclosure redistributes mfg
A→C Combined No leftover mystery math

Arms: A = v0.3 pinned (CEDA, 2018 MECS); B = GHG_national_Cornerstone_2024_mecs2018_isolation (flowsa, 2018 MECS, ratio_mecs_year: 2022); C = cb_mecs production (flowsa, 2022 MECS).

@bl-young

bl-young commented Sep 4, 2026

Copy link
Copy Markdown
Member

Findings comparing A (pinned v0.3 method using old CEDA allocators and 2018 MECS data) to B (new approach, still using 2018 MECS data). Results are B relative to A:

Stationary Combustion

Non-Manufacturing

  1. Non-mfg petroleum +7 Mt at uniform +4.9% — Non-mfg petroleum_industrial rises 142.614 → 149.615 Mt (+7.001). Every non-mfg petroleum sector scales by the same +4.91% (factor 1.049); within-non-mfg shares match A exactly. Those non-mfg stationary-combustion increases are only this pool increase — not a remapping among non-mfg sectors.
  2. No change in NG or Coal non-manufacturing.

Manufacturing

  1. Coal manufacturing combustion emissions spreads to more sectors — Total emissions are flat, but are spread across more sectors in new approach where those sectors report * or < 0.5 TBtu (assigned as 0.25 TBtu), instead of dropped in v0.3. 44 new sectors report minimal coal combustion emissions (60 vs 16)
  2. Natural gas manufacturing combustion emissions, adjustments to residual approach and mapping — Mfg ng_manufacturing pool is flat (378 Mt); same ~247 sectors on both arms; |sector churn| ≈ 7.4 Mt (share remapping only). Arm B weights come from Energy FBS table_3_1_ng: published MECS leaves keep their amounts; parent incomplete-child residuals are split with BEA_Detail_Use purchases of natural gas. Arm A uses curated CEDA industry→MECS lists (often equal among target leaves).

Non-energy use

  1. F01000 lubricants fully explain the change in transportation lubricants— Routing transport lubricants to households adds F01000 +3.442 Mt on NEU (was 0 under v0.3). That gain is exactly offset by losses on the prior absorbers: transport 48/49 (−2.155 Mt), GSLGO (−0.837), and special S00* (−0.450).

in progress

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

EIA_MECS_Energy_Allocation_CEDA labels 2022 MECS but allocates with 2018 survey tables

2 participants